<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <button></button>
    <script>
        //普通
        function fn() {
            console.log('66666');

        }
        fn();
        fn.call();
        //对象
        var o = {
            eat: function() {
                console.log("eat food?");

            }
        }
        o.eat();
        //构造函数
        function Eat() {

        };
        new Eat();
        var btn = document.querySelector("button");
        btn.onclick = function() {

        };
        //定时器
        //立即执行函数
        (function() {
            console.log("6666");

        })()
    </script>
</body>

</html>